﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using Axis.Web.FrontEnd.Views.News;
namespace Axis.Web.Views.News.Service
{
    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    [System.ComponentModel.ToolboxItem(false)]
    // To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line. 
    // [System.Web.Script.Services.ScriptService]
    [System.Web.Script.Services.ScriptService]
    public class NewsService : System.Web.Services.WebService
    {

        [WebMethod(EnableSession = true)]
        public string GetListNews(string catID, string page, string rows)
        {
            CNewUI UI = new CNewUI();
            return UI.GetNewList(catID, page, rows);
        }
        [WebMethod(EnableSession = true)]
        public string GetNewListByHome(string page, string rows)
        {
            CNewUI UI = new CNewUI();
            return UI.GetNewListByHome(page, rows);
        }
        [WebMethod(EnableSession = true)]
        public string GetTop10(string catID)
        {
            CNewUI UI = new CNewUI();
            return UI.GetTop10(catID);
        }
        [WebMethod(EnableSession = true)]
        public string GetTop1(string catID)
        {
            CNewUI UI = new CNewUI();
            return UI.GetTop1(catID);
        }
        [WebMethod(EnableSession = true)]
        public string GetNewsByTagID(string tagID, string page, string rows)
        {
            CNewUI UI = new CNewUI();
            return UI.GetNewsByTagID(tagID, page, rows);
        }

        [WebMethod(EnableSession = true)]
        public string GetNewsByID(string ID)
        {
            CNewUI UI = new CNewUI();
            return  UI.GetNewsDetail2(ID);
        }
         [WebMethod(EnableSession = true)]
        public string GetNewStatitic(string ID)
        {
            CNewUI UI = new CNewUI();
            return UI.GetNewStatitic(ID);
        }
        
       [WebMethod(EnableSession = true)]
        public string GetNewsRelation(string ID)
        {
            CNewUI UI = new CNewUI();
            return UI.GetNewsRelation(ID);
        }
    }
}
